add engine_preparePayload_debug endpoint#4427
Conversation
5daa0ad to
d2a46f4
Compare
|
Since this is a debug method, would it be simpler to use if it always built on the chainhead? It would be less timing/juggling when it is being used. |
yes, yes it would 👍 . I think we can do the same thing we do with timestamp and default it to the current head if it is otherwise not specified |
a08359a to
097264e
Compare
0cb6ee6 to
097e121
Compare
|
Hi Gary, can this be closed since it's been merged as part of another PR? |
097e121 to
35c9fb9
Compare
this was merged in a speculative RC candidate, and isn't in main yet. |
bd81e68 to
0166200
Compare
|
can we close or re-status this @garyschulte ? |
|
IMO we should rebase and merge as it is useful for debugging proposals. @fab-10 was using a different mechanism to test proposals IIRC, so would be helpful to get his opinion |
It make sense to have this endpoint as well, it is an easier and fast method to trigger a payload creation |
...hyperledger/besu/ethereum/api/jsonrpc/internal/methods/engine/EnginePreparePayloadDebug.java
Outdated
Show resolved
Hide resolved
...hyperledger/besu/ethereum/api/jsonrpc/internal/parameters/EnginePreparePayloadParameter.java
Outdated
Show resolved
Hide resolved
0166200 to
154f2fb
Compare
| ENGINE_GET_PAYLOAD_BODIES_BY_RANGE_V1("engine_getPayloadBodiesByRangeV1"), | ||
| ENGINE_EXCHANGE_CAPABILITIES("engine_exchangeCapabilities"), | ||
|
|
||
| ENGINE_PREPARE_PAYLOAD_DEBUG("engine_preparePayload_debug"), |
There was a problem hiding this comment.
Here is a tricky question, shouldn't this method be in the debug set? Another reason to move that is, the way we built the engine_exchange_capabilities mean Besu might report this method. CL is probably going to ignore it though.
There was a problem hiding this comment.
DEBUG is present even if the ENGINE api is not, so I think this needs to live within engine api. Good point about the capabilities though 🤔 I will check to see if this causes problems for CLs
There was a problem hiding this comment.
What about a ENGINE_DEBUG set? So it is separated from ENGINE and can be enabled only if used
There was a problem hiding this comment.
I filtered the debug prepare payload from the capabilities list in the same way the capabilities list filters itself 👍
There was a problem hiding this comment.
just saw the ENGINE_DEBUG set suggestion. I think we could add something like that if we have more than one engine debug endpoint in the future 👍 . Rule of three applies in this case IMO
...hyperledger/besu/ethereum/api/jsonrpc/internal/methods/engine/EnginePreparePayloadDebug.java
Outdated
Show resolved
Hide resolved
Signed-off-by: garyschulte <garyschulte@gmail.com>
Signed-off-by: garyschulte <garyschulte@gmail.com>
…, unit test coverage Signed-off-by: garyschulte <garyschulte@gmail.com>
154f2fb to
c845900
Compare
Signed-off-by: garyschulte <garyschulte@gmail.com>
Signed-off-by: garyschulte <garyschulte@gmail.com>
Signed-off-by: garyschulte <garyschulte@gmail.com>
Signed-off-by: garyschulte <garyschulte@gmail.com>
PR description
PR to enable debugging block proposals by re-adding an updated version of the deprecated
engine_preparePayloadendpointbe sure to use the current or a recent parent blockhash or you will DoS bonsai db
All fields in the parameter are optional, including the parameter itself
example usage:
OR, this usage will use fee recipient 0x00..00, current timestamp, current chain head, "deadbeef" prevrandao, and empty withdrawals:
Fixed Issue(s)
Documentation
doc-change-requiredlabel to this PR ifupdates are required.
Changelog